/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.modelo;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import javax.persistence.*;

/**
 *
 * @author Gilberto
 */
@Entity
@Table(name = "sintegra_60m")
@NamedQueries({
    @NamedQuery(name = "Sintegra60m.findAll", query = "SELECT s FROM Sintegra60m s")})
public class Sintegra60m implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Basic(optional = false)
    @Column(name = "ID")
    private Integer id;
    @Column(name = "DATA_EMISSAO")
    @Temporal(TemporalType.DATE)
    private Date dataEmissao;
    @Column(name = "NUMERO_SERIE_ECF")
    private String numeroSerieEcf;
    @Column(name = "NUMERO_EQUIPAMENTO")
    private Integer numeroEquipamento;
    @Column(name = "MODELO_DOCUMENTO_FISCAL")
    private String modeloDocumentoFiscal;
    @Column(name = "COO_INICIAL")
    private Integer cooInicial;
    @Column(name = "COO_FINAL")
    private Integer cooFinal;
    @Column(name = "CRZ")
    private Integer crz;
    @Column(name = "CRO")
    private Integer cro;
    // @Max(value=?)  @Min(value=?)//if you know range of your decimal fields consider using these annotations to enforce field validation
    @Column(name = "VALOR_VENDA_BRUTA")
    private BigDecimal valorVendaBruta;
    @Column(name = "VALOR_GRANDE_TOTAL")
    private BigDecimal valorGrandeTotal;
    @OneToMany(cascade = CascadeType.ALL, mappedBy = "idSintegra60m")
    private List<Sintegra60a> sintegra60aList = new ArrayList<>();

    public Sintegra60m() {
    }

    public Sintegra60m(Integer id) {
        this.id = id;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Date getDataEmissao() {
        return dataEmissao;
    }

    public void setDataEmissao(Date dataEmissao) {
        this.dataEmissao = dataEmissao;
    }

    public String getNumeroSerieEcf() {
        return numeroSerieEcf;
    }

    public void setNumeroSerieEcf(String numeroSerieEcf) {
        this.numeroSerieEcf = numeroSerieEcf;
    }

    public Integer getNumeroEquipamento() {
        return numeroEquipamento;
    }

    public void setNumeroEquipamento(Integer numeroEquipamento) {
        this.numeroEquipamento = numeroEquipamento;
    }

    public String getModeloDocumentoFiscal() {
        return modeloDocumentoFiscal;
    }

    public void setModeloDocumentoFiscal(String modeloDocumentoFiscal) {
        this.modeloDocumentoFiscal = modeloDocumentoFiscal;
    }

    public Integer getCooInicial() {
        return cooInicial;
    }

    public void setCooInicial(Integer cooInicial) {
        this.cooInicial = cooInicial;
    }

    public Integer getCooFinal() {
        return cooFinal;
    }

    public void setCooFinal(Integer cooFinal) {
        this.cooFinal = cooFinal;
    }

    public Integer getCrz() {
        return crz;
    }

    public void setCrz(Integer crz) {
        this.crz = crz;
    }

    public Integer getCro() {
        return cro;
    }

    public void setCro(Integer cro) {
        this.cro = cro;
    }

    public BigDecimal getValorVendaBruta() {
        return valorVendaBruta;
    }

    public void setValorVendaBruta(BigDecimal valorVendaBruta) {
        this.valorVendaBruta = valorVendaBruta;
    }

    public BigDecimal getValorGrandeTotal() {
        return valorGrandeTotal;
    }

    public void setValorGrandeTotal(BigDecimal valorGrandeTotal) {
        this.valorGrandeTotal = valorGrandeTotal;
    }

    public List<Sintegra60a> getSintegra60aList() {
        return sintegra60aList;
    }

    public void setSintegra60aList(List<Sintegra60a> sintegra60aList) {
        this.sintegra60aList = sintegra60aList;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (id != null ? id.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof Sintegra60m)) {
            return false;
        }
        Sintegra60m other = (Sintegra60m) object;
        if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "br.com.classes.Sintegra60m[ id=" + id + " ]";
    }
    
}
